<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"
	xmlns:h="http://xmlns.jcp.org/jsf/html"
	xmlns:f="http://xmlns.jcp.org/jsf/core"
	xmlns:ui="http://xmlns.jcp.org/jsf/facelets"
	xmlns:c="http://xmlns.jcp.org/jsf/composite"
	xmlns:p="http://primefaces.org/ui">
<h:head>
	<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
	<meta http-equiv="Pragma" content="no-cache" />
	<meta http-equiv="Expires" content="-1" />
	<title>VEND MACHINE</title>
	<link href="imagens/favicon.png" type="image/png" rel="shortcut icon" />
	<link type="text/css" rel="stylesheet"
		href="#{request.contextPath}/css/skytef.css" />


</h:head>
<h:body styleClass="body">
	<ui:include src="header.xhtml" />
	<div class="central">
		<h:form id="form" style="padding-top: 80px">


			<p:panel id="localizar" header="Cadastrar Usuário"
				style="margin-left:30px;margin-right:30px">
				<p:messages id="messages" showDetail="true" autoUpdate="true"
					closable="true" />
			<p:panel style="margin-top:2%">
				<p:panelGrid columns="2">

					<p:column>
						<h:outputLabel for="nome" value="Nome* : " style="font-size: 14px" />
						<p:inputText id="nome" label="Nome" required="true"
							requiredMessage="Preencha o campo Nome"
							style="font-size: 18px; width: 185px; left:auto; margin-right:3px;"
							value="#{CadUsuarioBean.usuario.name}" />
					</p:column>
					<p:column>
						<h:outputLabel for="cargo" value="Cargo : "
							style="font-size: 14px" />
						<p:inputText id="cargo" label="Cargo"
							style="font-size: 18px; width: 185px; left:auto; margin-right:3px;"
							value="#{CadUsuarioBean.usuario.post}" />
					</p:column>
					<p:column>
						<h:outputLabel for="login" value="Login* : "
							style="font-size: 14px" />
						<p:inputText id="login" label="Login" required="true"
							requiredMessage="Preencha o campo Login"
							style="font-size: 18px; width: 185px; left:auto; margin-right:3px;"
							value="#{CadUsuarioBean.usuario.login}" />
					</p:column>
					<p:column>
						<h:outputLabel for="senha" value="Senha* : "
							style="font-size: 14px" />
						<h:inputSecret id="senha" label="Senha" required="true"
							requiredMessage="Preencha o campo Senha"
							style="font-size: 18px; width: 185px; left:auto; margin-right:3px;"
							value="#{CadUsuarioBean.usuario.password}" />
					</p:column>
					<p:column>
						<h:outputLabel for="confsenha" value="Confirmar Senha* : "
							style="font-size: 14px" />
						<h:inputSecret id="confsenha" label="ConfSenha" required="true"
							requiredMessage="Preencha o campo Confirmar senha"
							style="font-size: 18px; width: 185px; left:auto; margin-right:3px;"
							value="#{CadUsuarioBean.confpassword}" />
					</p:column>
				</p:panelGrid>
				
				<p:commandButton id="salvar" value="Salvar" update="form"
					actionListener="#{CadUsuarioBean.salvar}" ajax="false"
					style="width: 10%;margin-top:2%;margin-left:0%"
					oncomplete="handleLoginRequest(xhr, status, args)" />
			</p:panel>
			</p:panel>
		</h:form>
		<p:panel id="cr" style="background: transparent; border: 0px;">
			<ui:include src="#{DashboardBean.currentRodape}" />
		</p:panel>
	</div>
	<div>
		<p:panel id="cm" style="background: transparent; border: 0px;">
			<ui:include src="#{DashboardBean.currentMenu}" />
		</p:panel>
	</div>


</h:body>
</html>